#!/bin/sh
#log_dir=/etc/log
#mkdir -p $log_dir

sh_filename=`readlink -f $0`
sh_dir=`dirname $sh_filename`

file=$sh_dir/test.log

echo "--------------------------------------------" >> $file
echo "`date`" >> $file

echo "1/2 login net" >> $file
$sh_dir/login_net.sh >> $file
sleep 1
echo "2/2 update_chinadns" >> $file
$sh_dir/update_chinadns.sh  1>$file 2>&1

sleep 3
echo "[$(date)] reboot the router" >> $file

reboot



